#以下是切片
v1 = "hellow word"
v2 = v1[2:4]  # 进行切片范围是 2<=  <4
print(v2)
#以下是判断开头
name = "wocao"
flag = name.startswith("wo")
print(flag)
#以下是加入
name = "alex"
result = "_".join(name)
print(result)
#以下是计算长度,并反向输出
v1 = "hellow word"
v_len = len(v1)
index = v_len - 1
while True:
    count = v1[index]
    index -= 1
    print(count)

#以下是列表
user = ["火火火", "吼吼吼", "好好好", "呵呵呵"]
count = 0
user_len = len(user)
for count in range(0, user_len):  # 将count逐一赋值，在输出count同时索引，一并输出
    print(count, user[count])
